let num = "123456789";

let regex = /^[0-9]{9}$/;

let res = regex.test(num);
console.log(res);
